import Vue from 'vue'
import Vuex from 'vuex'
import state from './state'
import getters from './getters'
import mutations from './mutations'
import actions from './actions'
import modules from './modules'
import createVuexAlong from 'vuex-along'

Vue.use(Vuex)

export default new Vuex.Store({
    state,
    mutations,
    actions,
    getters,
    modules,
    plugins: [createVuexAlong({
        name:'store-vuex-along',
        local: {
            list: ["ma"],
            isFilter: true // 过滤模块 ma 数据， 将其他的存入 localStorage
          },
          session: {
            list: ["count", "ma.a1"] // 保存 count 和模块 ma 中的 a1 到 sessionStorage
          }

    }
     





    )]
})
